package com.ease.util {
   import com.ease.util.reflection.TagArgReflectionInfo;

   /**
    * @private
    *
    * Contains info about a method or property and one of the metatags it's tagged with.
    */
   public class TaggedMemberInfo
   {
      private var _declaringTypeName:String;
      private var _declaringType:Class;
      private var _moduleReference:*;

      /** The type name on which the method or property is declared or defined. */
      public function get declaringTypeName():String {
         return _declaringTypeName;
      }

      /** @private */
      public function set declaringTypeName(value:String):void {
         _declaringTypeName = value;
      }

      /** A reference to the module containing the type. */
      public function get moduleReference():* {
         return _moduleReference;
      }

      /** @private */
      public function set moduleReference(value:*):void {
         _moduleReference = value;
      }

      /** The type on which the method or property is declared or defined. */
      public function get declaringType():Class {
         if (_declaringType == null) {
            _declaringType =
               ReflectionUtil.getDefinition(this.declaringTypeName, this.moduleReference);
         }
         return _declaringType;
      }

      /** Name of the property or method represented by this info object. */
      public var name:String;

      /**
       * May be null if the tag has no value (i.e., the tag is of the form [SomeTag]), or if
       * tagArgs is non-null.
       */
      [Optional]
      public var tagValue:Object;

      /**
       * Contains the key and value attributes representing the tag parameters.
       * For example, the following would result in 2 <code>TagArgReflectionInfo</code>
       * objects:
       *
       * <p><code>[SomeTag(key1="val1", key2="val2")]</code>
       *
       * <p>Maye be null if tagValue is non-null.
       */
      [Optional]
      public var tagArgs:Vector.<TagArgReflectionInfo>;
   } // class

}